import {NgModule} from '@angular/core';
import {RouterModule, Routes} from '@angular/router';

const routes: Routes = [
  {path: '', pathMatch: 'full', redirectTo: '/query'},
  {path: 'query', loadChildren: () => import('./pages/query/query.module').then(m => m.QueryModule)},
  {path: 'eventValueQuery', loadChildren: () => import('./pages/eventValueQuery/eventValueQuery.module').then(m => m.EventValueQueryModule)},
  {path: 'aggregateQuery', loadChildren: () => import('./pages/aggregateQuery/aggregateQuery.module').then(m => m.AggregateQueryModule)},
  {path: 'windowAggregateQuery', loadChildren: () => import('./pages/windowAggregateQuery/windowAggregateQuery.module').then(m => m.WindowAggregateQueryModule)},
  {path: 'windowResultQuery', loadChildren: () => import('./pages/windowResultQuery/windowResultQuery.module').then(m => m.WindowResultQueryModule)},
  {path: 'ruleQuery', loadChildren: () => import('./pages/ruleQuery/ruleQuery.module').then(m => m.RuleQueryModule)},
  {path: 'addRule/:id', loadChildren: () => import('./pages/addRule/addRule.module').then(m => m.AddRuleModule)},
  {path: 'rulePointQuery', loadChildren: () => import('./pages/rulePointQuery/rulePointQuery.module').then(m => m.RulePointQueryModule)},
  {path: 'monitor', loadChildren: () => import('./pages/monitor/monitor.module').then(m => m.MonitorModule)},
  {
    path: 'systemMonitor',
    loadChildren: () => import('./pages/systemMonitor/systemMonitor.module').then(m => m.SystemMonitorModule)
  },
  {path: 'r2dbcPool', loadChildren: () => import('./pages/r2dbcPool/r2dbcPool.module').then(m => m.R2dbcPoolModule)},
  {
    path: 'cassandraPool',
    loadChildren: () => import('./pages/cassandraPool/cassandraPool.module').then(m => m.CassandraPoolModule)
  },
  {path: 'welcome', loadChildren: () => import('./pages/welcome/welcome.module').then(m => m.WelcomeModule)}
];

@NgModule({
  imports: [RouterModule.forRoot(routes)],
  exports: [RouterModule]
})
export class AppRoutingModule {
}
